package simplex

/**
 * Clase para probar el algoritmo de Simplex.
 * 
 * @author age, joaquinmonleon
 *
 */
object Test {
  def main(args: Array[String]): Unit = {
    
    /*var r1:Racional = -2.5;
    println(r1);*/
    
    //println(Double.MaxValue);
    //var min:Racional = Double.MaxValue;
    
    
    var s = new Simplex(-1, false, "z", 
        Array(-1.0,2.0,-1.0),
        Array(12.0,6.0,9.0),
        3,3,
        Array(
            Array(1.0,1.0,1.0),
            Array(2.0,1.0,-1.0),
            Array(-1.0,3.0,0.0))
    )
    println("SOLUCION: "+s.resuelve())

    s = new Simplex(-1, false, "z", 
        Array(-3,-4),
        Array(8,6,6),
        2,3,
        Array(
            Array(2,1),
            Array(-1,2),
            Array(1,1))
    )
    println("SOLUCION: "+s.resuelve())
    
    
  }
}
